package cn.domain;

import java.util.Hashtable;

public class TunnelType {
	private static Hashtable<String,String> nodeType=new Hashtable<String, String>();
	private static Hashtable<String,String> nodeUnit=new Hashtable<String, String>(); 
 	static {
 		nodeUnit.put("1"," °C");
		nodeUnit.put("2"," %RH");
		nodeUnit.put("3"," Lux");
		nodeUnit.put("4"," °C");
		nodeUnit.put("5"," V");
		nodeUnit.put("6"," KPa");
		nodeUnit.put("7"," 压力/液位");
		nodeUnit.put("8"," 流量");
		nodeUnit.put("9"," 超声波");
		nodeUnit.put("a"," 雷达");
		nodeUnit.put("b"," 单界面");
		nodeUnit.put("c"," 双界面");
		nodeUnit.put("d"," 浸水");
		nodeUnit.put("e"," 感烟器");
		nodeUnit.put("f"," 明火探测器");
		nodeUnit.put("10"," 红外探测器");
		nodeUnit.put("11"," 射频物位开关");
		nodeUnit.put("12"," 浮球开关");
		nodeUnit.put("13"," 音叉物位开关");
		nodeUnit.put("14"," ppm");
		nodeUnit.put("15"," 粉尘");
		nodeUnit.put("16"," 空气质量等级");
		nodeUnit.put("17"," 一氧化碳");
		nodeUnit.put("18"," 氢气");
		nodeUnit.put("19"," 硫化氢");
		nodeUnit.put("1a"," 氧气");
		nodeUnit.put("1b"," 二氧化硫");
		nodeUnit.put("1c"," 氯气");
		nodeUnit.put("1d"," 氨气");
		nodeUnit.put("1e"," 甲醇");
		nodeUnit.put("1f"," 乙醇");
		nodeUnit.put("20"," 甲烷");
		nodeUnit.put("21"," 露点");
		nodeType.put("1"," 温度");
		nodeType.put("2"," 湿度");
		nodeType.put("3"," 照度");
		nodeType.put("4"," 土壤温度");
		nodeType.put("5"," 土壤水分");
		nodeType.put("6"," 大气压力");
		nodeType.put("7"," 压力/液位");
		nodeType.put("8"," 流量");
		nodeType.put("9"," 超声波");
		nodeType.put("a"," 雷达");
		nodeType.put("b"," 单界面");
		nodeType.put("c"," 双界面");
		nodeType.put("d"," 浸水");
		nodeType.put("e"," 感烟器");
		nodeType.put("f"," 明火探测器");
		nodeType.put("10"," 红外探测器");
		nodeType.put("11"," 射频物位开关");
		nodeType.put("12"," 浮球开关");
		nodeType.put("13"," 音叉物位开关");
		nodeType.put("14"," 二氧化碳");
		nodeType.put("15"," 粉尘");
		nodeType.put("16"," 空气质量等级");
		nodeType.put("17"," 一氧化碳");
		nodeType.put("18"," 氢气");
		nodeType.put("19"," 硫化氢");
		nodeType.put("1a"," 氧气");
		nodeType.put("1b"," 二氧化硫");
		nodeType.put("1c"," 氯气");
		nodeType.put("1d"," 氨气");
		nodeType.put("1e"," 甲醇");
		nodeType.put("1f"," 乙醇");
		nodeType.put("20"," 甲烷");
		nodeType.put("21"," 露点");

		nodeType.put("30"," 风速");
		nodeType.put("31"," 风向");
		nodeType.put("32"," 雨量");

		nodeType.put("a1"," 开关量1（输出）");
		nodeType.put("a2"," 开关量2（输出）");
		nodeType.put("a3"," 开关量3（输出）");
		nodeType.put("a4"," 开关量4（输出）");
		nodeType.put("a5"," 开关量5（输出）");
		nodeType.put("a6"," 开关量6（输出）");
		nodeType.put("a7"," 开关量7（输出）");
		nodeType.put("a8"," 开关量8（输出）");
		nodeType.put("a9"," 开关量9（输出）");
		nodeType.put("aa"," 开关量10（输出）");
		nodeType.put("c2"," 模拟量1（mA）");
		nodeType.put("c3"," 模拟量2（mA）");
		nodeType.put("c4"," 模拟量3（mA）");
		nodeType.put("c5"," 模拟量4（mA）");
		nodeType.put("c6"," 模拟量5（mA）");
		nodeType.put("c7"," 模拟量1（V）");
		nodeType.put("c8"," 模拟量2（V）");
		nodeType.put("c9"," 模拟量3（V）");
		nodeType.put("ca"," 模拟量4（V）");
		nodeType.put("f1"," 设备版本");
		nodeType.put("f2"," 设备电量");
		nodeType.put("ff"," 路由心跳");
	} 
     @SuppressWarnings("unused")
	 public static String getTunnelNameByKey(String key){
    	 return nodeType.get(key);
     }

	public static String getTunnelUnitByKey(String type) {
		 return nodeUnit.get(type);
	}
}
